<template>
  <div class="city">
    <CityHeader></CityHeader>
    <!-- <HotCity :hotCities='hotCities'></HotCity> -->
    <!-- <sort :cities='cities'></sort> -->
    <List :cities='cities' :hotCities='hotCities'></List>
  </div>
</template>

<script>
  import CityHeader from './pages/header.vue'
  // import HotCity from './pages/hotcity.vue'
  // import Sort from './pages/sort.vue'
  import List from './pages/list.vue'
  export default {
    components: {
      CityHeader,
      // HotCity,
      // Sort,
      List
    },
    data() {
      return {
        hotCities: [],
        cities: []
      }
    },
    mounted() {
      this.$http.get('http://localhost:8080/static/mock/city.json').then(res => {

        let data = res.data.data
        this.hotCities = data.hotCities
        this.cities = data.cities
      })
    }
  }
</script>

<style>
  .city {
    background-color: #f5f5f5;
  }
</style>
